﻿#pragma once
#include "D3DUtil.h"

class TextureManager 
{
public:
    virtual  void LoadTexture(
      ID3D12Device* device,
      ID3D12GraphicsCommandList* cmdList) = 0;

    virtual  void BuildDescriptorHeap(
        ID3D12Device* device,
        CD3DX12_CPU_DESCRIPTOR_HANDLE hCpuDescriptor,
        UINT cbvSrvDescriptorSize) = 0;


    UINT DescriptorCount() {return mDescriptorSize;}
    
public:
    const std::unordered_map<std::string,std::unique_ptr<Texture>>& GetTextures() const;
protected:
    std::unordered_map<std::string,std::unique_ptr<Texture>> mTextures;
    UINT mDescriptorSize;
};
